package com.weicp.demo.web;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 *
 */
@Controller
public class ApiController {

    private Logger logger = LoggerFactory.getLogger(getClass());

    @RequestMapping("/demo/api")
    public @ResponseBody String api(){
        logger.info("demo-Api");
        return "demo";
    }

    @RequestMapping("/echo")
    public @ResponseBody String echo(){
        return "OK";
    }
}
